package com.kanshu.ksgb.fastread.doudou.module.bookcity.view;

import android.content.Context;
import android.support.annotation.Nullable;
import android.util.AttributeSet;
import android.view.LayoutInflater;
import android.view.View;
import android.widget.LinearLayout;
import android.widget.TextView;

import com.kanshu.ksgb.fastread.doudou.R;
import com.lcodecore.tkrefreshlayout.IBottomView;

/**
 * Created by wcy on 18/5/17.
 */

public class MaleOrFemaleFooter extends LinearLayout implements IBottomView {
    TextView mTip;
    public MaleOrFemaleFooter(Context context) {
        super(context);
        init();
    }

    public MaleOrFemaleFooter(Context context, @Nullable AttributeSet attrs) {
        super(context, attrs);
        init();
    }

    public MaleOrFemaleFooter(Context context, @Nullable AttributeSet attrs, int defStyleAttr) {
        super(context, attrs, defStyleAttr);
        init();
    }

    private void init() {
        LayoutInflater.from(getContext()).inflate(R.layout.item_selected_male_or_female_layout, this);
        mTip = (TextView) findViewById(R.id.tip);
    }

    @Override
    public View getView() {
        return this;
    }

    @Override
    public void onPullingUp(float fraction, float maxBottomHeight, float bottomHeight) {
    }

    @Override
    public void startAnim(float maxBottomHeight, float bottomHeight) {

    }

    @Override
    public void onPullReleasing(float fraction, float maxBottomHeight, float bottomHeight) {
    }

    @Override
    public void onFinish() {

    }

    @Override
    public void reset() {
    }

    public void setTip(CharSequence tip) {
        mTip.setText(tip);
    }
}
